package com.lbd.email.service;

import com.lbd.base.service.BaseService;
import com.lbd.email.bean.EmailTemplate;
import com.lbd.system.bean.User;

import java.util.Map;

/**
 * Created by wang on 2016/9/23.
 */
public interface EmailTemplateService extends BaseService<EmailTemplate> {
    /**
     * 根据id查询邮件模板信息
     *
     * @param id
     * @return
     */
    EmailTemplate findById(String id);

    /**
     * 发送邮件
     *
     * @param user 接收者
     * @param code key
     * @param data value
     */
    void sendEmail(User user, String code, Map<String, Object> data);
}
